package com.demo.component.configuration;

import com.demo.entity.LoginUserBean;

public class LocalContext {

	private static ThreadLocal<LoginUserBean> loginThreadLocal = new ThreadLocal<LoginUserBean>();

    public static LoginUserBean getLoginUserBean(){
    	return loginThreadLocal.get();
    }

    public static String getToken(){
        return loginThreadLocal.get().getToken();
    }

    public static void setLoginUserBean(LoginUserBean value)
    {
        loginThreadLocal.set(value);
    }

    public static void clear()
    {
        loginThreadLocal.remove();
    }



}
